(function () {
    return {
        initControl: function (oControl) {
            var v = oControl.value;
            v.datavar = 0;
            v.title = "检查框";
        },
        compile: function (compileContext, doc, entity) {
            var cc = compileContext;
            var tc = cc.templateCoder;

            var dataName = cc.findDataName(doc,entity.value.datavar);

            if( dataName)
                cc.dataNames.push(dataName);

            cc.templateCoder.add("<label class=\"checkbox no-selected flex-middle\" ><input type=\"checkbox\" :value=\"" + dataName + ".value\">");
            cc.templateCoder.add("<span class=\"lp - m\">"+entity.value.title+"</span></label>");

        }
    }
})();